package com.pocket.insight.entity;

import java.util.List;
import java.util.Set;

/**
 * 描述：
 *
 * @author shuize
 * @create 2024/12/10
 */
public class ObjectGroup {
    private Long                id;
    private String              name;
    private ObjectGroupTypeEnum type;
    private int                 displayIndex;
    private Long                appId;
    private Long                datasetId;
    private List<String>        children;

    public enum ObjectGroupTypeEnum {
        CONNECTION, APP, DATASET, FIELD, METRIC, APP_PARAM;

        static {
            APP_OBJECT = Set.of(new ObjectGroupTypeEnum[]{APP_PARAM});
            DATASET_OBJECT = Set.of(new ObjectGroupTypeEnum[]{FIELD, METRIC});
        }

        public static final Set<ObjectGroupTypeEnum> DATASET_OBJECT;
        public static final Set<ObjectGroupTypeEnum> APP_OBJECT;
    }
}
